package com.ruicar.afs.cloud.afscase.loandealerfirstmortgage.service.impl;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.ruicar.afs.cloud.afscase.loandealerfirstmortgage.condition.LoanDealerFirstMortgageCondition;
import com.ruicar.afs.cloud.afscase.loandealerfirstmortgage.vo.LoanDealerFirstMortgageVO;
import com.ruicar.afs.cloud.afscase.loandealerfirstmortgage.entity.LoanDealerFirstMortgage;
import com.ruicar.afs.cloud.afscase.loandealerfirstmortgage.mapper.LoanDealerFirstMortgageMapper;
import com.ruicar.afs.cloud.afscase.loandealerfirstmortgage.service.LoanDealerFirstMortgageService;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class LoanDealerFirstMortgageServiceImpl extends ServiceImpl<LoanDealerFirstMortgageMapper, LoanDealerFirstMortgage> implements LoanDealerFirstMortgageService {

    /**
     * 获取所有合作商首单信息
     *
     * @param page
     * @param condition
     */
    @Override
    public IPage<LoanDealerFirstMortgage> getDealerFirstMortgageList(Page page, LoanDealerFirstMortgageCondition condition) {
        return this.baseMapper.getDealerFirstMortgageList(page,condition);
    }

    /**
     * 修改是否首单抵押状态
     *
     * @param idList
     * @param status
     * */
    @Override
    public Integer modifyIsFirstMortgage(List idList, String status) {
        return this.baseMapper.modifyIsFirstMortgage(idList, status);
    }

    /**
     * 合作商批量修改是否首单抵押状态
     *
     * @param channelCodeList
     * @param status
     */
    @Override
    public Integer modifyIsFirstMortgageList(List channelCodeList, String status) {
        return this.baseMapper.modifyIsFirstMortgageList(channelCodeList, status);
    }
}
